package com.frxuexi.shop2307.adapter

import androidx.databinding.DataBindingUtil
import com.chad.library.adapter.base.BaseQuickAdapter
import com.chad.library.adapter.base.viewholder.BaseViewHolder
import com.frxuexi.lib_base.entity.Child
import com.frxuexi.shop2307.R
import com.frxuexi.shop2307.databinding.ItemTypeTwoBinding

class TypeTwoAdapter:BaseQuickAdapter<Child,BaseViewHolder>(R.layout.item_type_two) {
    override fun onItemViewHolderCreated(viewHolder: BaseViewHolder, viewType: Int) {
        super.onItemViewHolderCreated(viewHolder, viewType)
        DataBindingUtil.bind<ItemTypeTwoBinding>(viewHolder.itemView)
    }
    override fun convert(helper: BaseViewHolder, item: Child) {
        DataBindingUtil.getBinding<ItemTypeTwoBinding>(helper.itemView)?.bean=item
    }
}